package com.dss.code_generation.vo;

import com.fasterxml.jackson.annotation.JsonFormat;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.AllArgsConstructor;
import lombok.Builder;
import lombok.Data;
import lombok.NoArgsConstructor;
import org.springframework.format.annotation.DateTimeFormat;

import java.util.Date;

/**
* @author dongshoushan
* @date 2022-09-06 15:29:28
*/
@Data
@NoArgsConstructor
@AllArgsConstructor
@Builder
@ApiModel(value = "虚拟机服务器")
public class ServerVo {

    /**
    * 主键
    */
    @ApiModelProperty(value = "主键")
    private Long id;

    /**
    * 服务器名称
    */
    @ApiModelProperty(value = "服务器名称")
    private String name;

    /**
    * 用户名
    */
    @ApiModelProperty(value = "用户名")
    private String username;

    /**
    * ip地址
    */
    @ApiModelProperty(value = "ip地址")
    private String ip;

    /**
    * 端口
    */
    @ApiModelProperty(value = "端口")
    private Integer port;

    /**
    * 密码
    */
    @ApiModelProperty(value = "密码")
    private String password;

    /**
     * 父级id，默认-1
     */
    @ApiModelProperty(value = "父级id，默认-1")
    private Long parentId;
    private String vpn;

    /**
    * 总内存大小,单位G
    */
    @ApiModelProperty(value = "总内存大小,单位G")
    private String memoryTotal;

    /**
    * 剩余内存大小,单位G
    */
    @ApiModelProperty(value = "剩余内存大小,单位G")
    private String memoryFree;

    /**
    * cpu利用率
    */
    @ApiModelProperty(value = "cpu利用率")
    private String cpu;

    /**
    * 排序
    */
    @ApiModelProperty(value = "排序")
    private Integer sort;

    /**
    * 创建时间
    */
    @ApiModelProperty(value = "创建时间")
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8")
    @DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    private Date createTime;

    /**
    * 更新时间
    */
    @ApiModelProperty(value = "更新时间")
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8")
    @DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    private Date updateTime;

    /**
     *  0文件夹 1服务器
     */
    private Integer type;



}
